my_list = [3, "apple", 9, "banana", 7, "cherry", 2, "date", 5, "elderberry"]
my_list.append("fig")
my_list.remove("banana")
my_list[6] = "grape"
c = my_list.index("cherry")
print(c)
for i in my_list:
    print(i)
my_list.insert(c + 1, "kiwi")

print(my_list[-2:-3:-1])
print(my_list[-1::-1])
my_list_str = sorted([s for i, s in enumerate(my_list) if type(s) is str])
new_my_list = []
a = 0
for i in my_list:
    if type(i) is str:
        new_my_list.append(my_list_str[a])
        a += 1
    else:
        new_my_list.append(i)
print(new_my_list)

for i in range(len(my_list)):
    if type(my_list[i]) is int:
        my_list[i] = str(my_list[i])
print(my_list)
